<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
<head>
	<th:block th:include="include :: header('修改行政区域')" />
</head>
<body class="white-bg">
    <div class="wrapper wrapper-content animated fadeInRight ibox-content">
        <form class="form-horizontal m" id="form-region-edit" th:object="${region}">
            <input id="regionId" name="regionId" th:field="*{regionId}"  type="hidden">
			<div class="form-group">	
				<label class="col-sm-3 control-label">区域名：</label>
				<div class="col-sm-8">
					<input id="regionName" name="regionName" th:field="*{regionName}" class="form-control" type="text">
				</div>
			</div>
			<div class="form-group">	
				<label class="col-sm-3 control-label">行政级别(1:省，2：市，3：区县)：</label>
				<div class="col-sm-8">
					<input id="regionLevel" name="regionLevel" th:field="*{regionLevel}" class="form-control" type="text">
				</div>
			</div>
			<div class="form-group">	
				<label class="col-sm-3 control-label">归属id：</label>
				<div class="col-sm-8">
					<input id="pId" name="pId" th:field="*{pId}" class="form-control" type="text">
				</div>
			</div>
			<div class="form-group">	
				<label class="col-sm-3 control-label">邮政编码：</label>
				<div class="col-sm-8">
					<input id="postalCode" name="postalCode" th:field="*{postalCode}" class="form-control" type="text">
				</div>
			</div>
		</form>
    </div>
    <div th:include="include::footer"></div>
    <script type="text/javascript">
		var prefix = ctx + "system/region";
		$("#form-region-edit").validate({
			rules:{
				xxxx:{
					required:true,
				},
			},
			focusCleanup: true
		});
		
		function submitHandler() {
	        if ($.validate.form()) {
	            $.operate.save(prefix + "/edit", $('#form-region-edit').serialize());
	        }
	    }
	</script>
</body>
</html>
